/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.fyx.secure.web;

import java.io.IOException;
import javax.ejb.EJB;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.SessionScoped;
import javax.faces.context.FacesContext;
import org.fyx.linker.web.LinkerLocal;
import org.fyx.secure.entity.SecureUser;
import org.fyx.secure.ejb.SecureLocal;

/**
 *
 * @author xljan
 */
@ManagedBean
@SessionScoped
public class SecureMb {
    @EJB
    private SecureLocal secure;
    @EJB
    private LinkerLocal linker;

    private SecureUser selectedUser;

    /** Creates a new instance of SecureMb */
    public SecureMb() {
    }

    public SecureLocal getSecure() {
        return secure;
    }

    public void setSecure(SecureLocal Secure) {
        this.secure = Secure;
    }

    public SecureUser getSelectedUser() {
        return selectedUser;
    }

    public void setSelectedUser(SecureUser selectedUser) {
        this.selectedUser = selectedUser;
    }

    public void deleteSelectedUser(){
        secure.deleteUser(selectedUser);
    }
}
